//
// Copyright (c) Microsoft Corporation.  All rights reserved.
//
//
// Use of this source code is subject to the terms of your Microsoft Windows CE
// Source Alliance Program license form.  If you did not accept the terms of
// such a license, you are not authorized to use this source code.
//

#ifndef __LOG_H
#define __LOG_H

//------------------------------------------------------------------------------

#ifdef __cplusplus
extern "C" {
#endif

//------------------------------------------------------------------------------

#define LOG_EXCEPTION           0
#define LOG_FAIL                2
#define LOG_WARNING             3
#define LOG_ABORT               4
#define LOG_SKIP                6
#define LOG_NOT_IMPLEMENTED     8
#define LOG_PASS                10
#define LOG_DETAIL              12
#define LOG_COMMENT             14

//------------------------------------------------------------------------------

typedef void (*PLOG_FUNCTION)(DWORD dwLevel, LPCTSTR sz);

void LogStartup(LPCTSTR szTestName, DWORD dwLogLevel, PLOG_FUNCTION pLogFce);
void LogCleanup();
void LogSetWATTOutput(BOOL bWATTOutput);
void LogSetLevel(DWORD dwLogLevel);
DWORD LogGetLevel();

void LogErr(LPCTSTR szFormat, ...);
void LogWrn(LPCTSTR szFormat, ...);
void LogMsg(LPCTSTR szFormat, ...);
void LogDbg(LPCTSTR szFormat, ...);
void LogVbs(LPCTSTR szFormat, ...);

void Log(DWORD dwLevel, LPCTSTR szFormat, ...);

DWORD LogGetErrorCount(void);
DWORD LogGetWarningCount(void);

//------------------------------------------------------------------------------

#ifdef __cplusplus
}
#endif

//------------------------------------------------------------------------------

#endif
